#include "sys_led.h"
#include "run.h"


#define  sys_led_times 500
sys_tim sys_led_tim;

void sys_led_app(void)
{
	if(sys_running_timer.ms-sys_led_tim.ms>=sys_led_times)
	{
		sys_led_tim=sys_running_timer;
		*IO.sys_led=~*IO.sys_led;
	}
	if(sys_status.run_mod==MOD_NULL)
	{
		led_yellow_ON;
		led_green_OFF;
	}
	else
	{
		led_yellow_OFF;
		if(sys_status.alarm_code==0)
		{
			led_green_ON;
		}
		else
		{
			led_green_OFF;
		}
	}
}




